﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Skyhook.Resources
{
    internal class ResourceCollection
    {
        Dictionary<string, Resource> Resources = new Dictionary<string, Resource>();

        public ResourceCollection()
        {
        }

        public void Add(Resource resource)
        {
            Resources.Add(resource.UID,resource);
        }

        public void Remove(Resource resource)
        {
            Resources.Remove(resource.UID);
        }

        public bool Contains(string uid)
        {
            return Resources.ContainsKey(uid);
        }

        public Resource this[string uid]
        {
            get
            {
                return Resources[uid];
            }
        }
    }
}
